<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>1</title>
    <script src="https://unpkg.com/vue@next"></script>
</head>

<body>
    <div id='root'>
       <counter ></counter>
       <hr>
       <counter ></counter>
       <hr>
       <counter ></counter>
       
    </div>
    <script>
        let app = Vue.createApp({
            data() {
                return {
                   
                }
            },
            methods:{
                handleButton(){
                   alert(1)
                }
            }
        })

        app.component('counter',{
            data(){
                return {
                    count:1
                }
            },
            template:`<div @click="count++">{{count}}</div>`
        })

        let vm = app.mount('#root')
    </script>
</body>
</html>